<template>
  <div class="affirmModalBody">
    <p class="header">{{title}}</p>
    <p class="tipMsg">{{tipMsg}}</p>
    <div class="modalFooter">
      <zdy-button @click="closeModal(false)">
        <span>取 消</span>
      </zdy-button>
      <zdy-button type="primary" style="margin-left: 8px;" @click="closeModal(true)">
        <span>确 定</span>
      </zdy-button>
    </div>
  </div>
</template>

<script>
import { reactive } from 'vue';
import ZdyButton from "@/components/ZdyButton/index.vue";

export default {
  name: "AffirmModalBody",
  props: {
    title: {
      type: String,
      default: "",
    },
    tipMsg: {
      type: String,
      default: "",
    },
  },
  components: {
    ZdyButton,
  },
  setup(props, context) {

    const bodyData = reactive({
    });


    //底部操作--关闭弹窗
    const closeModal = (res) => {
      context.emit("closeModal", res);
    }

    return {
      bodyData,
      closeModal,
    }
  },
}
</script>

<style lang="less" scoped>
.affirmModalBody {
  padding: 24px 24px 20px 20px;
  .header {
    font-size: 16px;
    font-weight: bold;
    line-height: 22px;
    margin-bottom: 17px;
    color: rgba(0, 0, 0, 0.85);
  }
  .tipMsg {
    font-size: 14px;
    line-height: 20px;
    color: rgba(0, 0, 0, 0.45);
  }
  .modalFooter {
    margin-top: 18px;
    text-align: right;
  }
}
</style>
